<?php

namespace backend\assets;
use yii\web\AssetBundle;
/**
 * Main backend application asset bundle.
 */
class AdminAsset extends AssetBundle
{
    public $sourcePath = '@app/assets/admin';
    public $css = [
       'css/bootstrap.min.css',
       'css/font-awesome.min.css',
       // 'css/ace.min.css',
       // 'css/ace-rtl.min.css',
       // 'css/ace-skins.min.css',
       //'css/jquery.treeview.css',
       //'css/jquery.treeTable.css',
        'css/swfupload.css',
        'css/paper.css',
        'css/themify-icons.css',
        'css/animate.min.css',
        'Simple-Calendar/css/simple-calendar.css',//日历插件
        'css/style.css',//重写样式写到这！！
    ];
    public $js = [
        //'js/jquery-2.1.4.js',
        'js/ace-extra.min.js',
        'js/ace-elements.min.js',
        'js/ace.min.js',
        //'js/jquery.treetable.js',
        'js/bootstrap.min.js',
        'js/layer/layer.js',
        'js/swfupload/swfupload.js',
        'js/swfupload/fileprogress.js',
        'js/swfupload/handlers.js',
        'js/dialog.js',
        'js/jquery.sgallery.js',
        'js/ajaxupload.js',
        'Simple-Calendar/js/simple-calendar.js',
        //'js/jquery.imgpreview.js',
        'js/chartist.min.js',//图表插件
        'js/bootstrap-notify.js',//通知插件
    ];
    public $depends = [
        'yii\web\YiiAsset',
        'yii\bootstrap\BootstrapAsset',
    ];

    //定义按需加载JS方法，注意加载顺序在最后
    public static function addScript($view,$jsfile) 
    {
        $view->registerJsFile($jsfile,[AdminAsset::className(),'depends'=>'backend\assets\AdminAsset']);
    }

    //定义按需加载CSS方法，注意加载顺序在最后
    public static function addCss($view,$cssfile)
    {
        $view->registerCssFile($cssfile,[AdminAsset::className(),'depends'=>'backend\assets\AdminAsset']);
    }
    
}
